namespace OpenWaves.Pagination
{
    public interface IPaginationUrlFactory
    {
        Url GetPageUrl(int pageIndex);
    }

    public static class PaginationUrlFactoryExtensions
    {
        public static Url GetPageUrl(this IPaginationUrlFactory factory, PageViewModel page)
        {
            return factory.GetPageUrl(page.Index);
        }
    }
}